<?xml version="1.0" encoding= "UTF-8"?>
<html xmlns="http://www.w3.org/1999/xhtml"
	xmlns:h="http://java.sun.com/jsf/html"
	xmlns:ui="http://java.sun.com/jsf/facelets"
	xmlns:f="http://java.sun.com/jsf/core"
	xmlns:p="http://primefaces.org/ui">

<ui:composition template="/templates/common.xhtml">
	<ui:define name="content">
		<h:form>
			<p:panel id="panel" header="Enter the Social Network">
				<h:panelGrid columns="3" cellpadding="5">

					<p:outputLabel for="email" value="Email:" />
					<p:inputText id="email" value="#{accountBean.email}"
						required="true" label="Email" requiredMessage="Email is required">
						<f:validator for="email" validatorId="emailValidator" />
					</p:inputText>
					<p:message for="email" />
					<p:outputLabel for="password" value="Password:"></p:outputLabel>
					<p:password id="password" minQueryLength="3"
						value="#{accountBean.password}" label="Password" required="true"
						requiredMessage="Password is required">

					</p:password>
					<p:message for="password" />
				</h:panelGrid>
				<p:commandButton value="Log in" action="#{accountBean.login}"
					update="panel"/>
				<br />
				<br />
				<h:link  outcome="registration" value="Create new account" update="panel"/>
                <br />
				<br />
				<h:link  outcome="forgot" value="Forgot your password ?" update="panel"/>

			</p:panel>


		</h:form>


	</ui:define>

</ui:composition>


</html>

